<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
	<link rel="stylesheet" type="text/css" href="view/default.css"/>
	<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
	<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
	<jsp:include page="head.html"/>
<script language="javascript">
<!--
function OnChange(dropdown)
{
    var SelValue = dropdown.options[myindex].value    
    return true;
}
//-->

</script>

</head>
<body>
	<div class="sidebar">
	<jsp:include page="navigation.jsp"/>
	</div>
	<div class="page">
		<h2><c:out value="${title}"/></h2>
		<p><c:out value="${message}"/></p>
		
		<!-- Dynamisches Dropdown Menü zur Auswahl des Studiengangs -->
		<select name="Studiengang" id="studiengang" onchange='OnChange(this.form.Studiengang);' >
			<option value="0">Waehle den Studiengang</option>
			<!-- Schleife durchläuft alle Studiengangsbjekte und zeigt den Namen im Dropdownmenü an -->
			<c:forEach items="${studiengaenge}" var="studiengang">
				<option value="${studiengang.idStudiengang}"><c:out value="${studiengang.name}"/></option>
			</c:forEach>	 
		</select>
		<c:out value="Studiengang", "$(SelValue)"/>
		<!-- Dynamisches Dropdown Menü zur Auswahl des Kurses -->
		<select name="Kurs" id="kurs" >
			<option value="0">Waehle den Kurs</option>
			<c:forEach items="${kurse}" var="kurs">
			
					<option value="${kurs.idKurs}"><c:out value="${kurs.name}"/></option>
					<!-- <c:if test='${studiengang.idStudiengang == "1"}'> -->	
					<!-- </c:if> -->
			</c:forEach>
		</select>
	</div>
			
</body>
</html>